package com.cennavi.minemap.util;

public enum TNaviTurnIconID {
	ENTI_None("无效", 0), 
	ENTI_GoStraight("直行", 5), 
	ENTI_TurnLeft("左转", 8), 
	ENTI_TurnRight("右转", 9),
	ENTI_TurnSlightlyLeft("向左前方行驶", 10),
	ENTI_TurnSlightlyRight("向右前方行驶", 11),
	ENTI_TurnHardLeft("向左后方行驶", 23),
	ENTI_TurnHardRight("向右后方行驶", 24),
	ENTI_KeepLeft("保持左侧行驶", 21),
	ENTI_KeepRight("保持右侧行驶", 22),
	ENTI_StraightKeepLeft("直行走左侧岔道", 39),
	ENTI_StraightKeepRight("直行走右侧岔道", 40),
	ENTI_TurnLeftKeepLeft("左转走左侧岔道", 25),
	ENTI_TurnLeftKeepRight("左转走右侧岔道", 26),
	ENTI_TurnRightKeepLeft("右转走左侧岔道", 27),
	ENTI_TurnRightKeepRight("右转走右侧岔道", 28),
	ENTI_TurnAround("掉头", 2);
    private String name ;
    private int index ;
     
    private TNaviTurnIconID( String name , int index ){
        this.name = name ;
        this.index = index ;
    }
     
    public String getName() {
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }
    public int getIndex() {
        return index;
    }
    public void setIndex(int index) {
        this.index = index;
    }
    
    public static String getName(int index) {
        for (TNaviTurnIconID c : TNaviTurnIconID.values()) {
            if (c.getIndex() == index) {
                return c.name;
            }
        }
        return null;
    }
}
